Various structures for protecting an LED (light emitting diode) from ESD (electrostatic discharge) have been proposed. However, in an LED having a chip size package structure, there is demand for providing ESD resistance without hindrance to downsizing.